package com.icss.id.service.Impl;

import com.icss.id.dao.ItemsDao;
import com.icss.id.pojo.Item;
import com.icss.id.service.ItemService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import java.util.List;
@Component
public class ItemServiceImpl implements ItemService {
    @Autowired
    private ItemsDao itemsDao;

    public List<Item> findItem() {
        List<Item> all = itemsDao.findAll();

        return all;
    }

    @Override
    public Item findByDelict(String delict) {
        Item byDelict = itemsDao.findByDelict(delict);

        return byDelict;
    }


}
